from pydantic import BaseModel, Field
from typing import Optional


class DictTypeCreate(BaseModel):
    type_code: str = Field(..., description="字典类型编码")
    type_name: str = Field(..., description="字典类型名称")
    type_desc: Optional[str] = Field(None, description="字典类型描述")


class DictTypeUpdate(BaseModel):
    type_code: Optional[str] = Field(None, description="字典类型编码")
    type_name: Optional[str] = Field(None, description="字典类型名称")
    type_desc: Optional[str] = Field(None, description="字典类型描述")